<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title></title>
        <style>
            input#email{
                height:30px;
            }
            input#pass{
                height:30px;
            }
            fieldset.login{
                width:480px;
                margin-left: 200px;    
            }
            #main{
                height: 800px;
            }
            legend{
                padding-left: 0px;
                width: 200px;
                text-align: center;
            }
        </style>
    </head>
    <body>
        <div id="wrapper">
            <div id="main">
                <fieldset class="login">
                    <legend>THÔNG TIN ĐĂNG NHẬP</legend>
                    <?php
                    @session_start();
                    if (isset($_SESSION['check'])) {
                        if ($_SESSION['check'] == 1) {
                            echo " <span class='error'>Bạn nhập sai email hoặc mật khẩu</span>";
                            unset($_SESSION['check']);
                            ?>
                            <form action="admin/login" method="POST" id="login">
                                <label><strong>Email:<span>(*)</span></strong></label>
                                <input type="text" size="50" name="email" id="email" class="required email" value="<?php echo $_SESSION['email'] ?>"/></br>
                                <label ><strong>Mật khẩu:<span>(*)</span></strong></label>
                                <input type="password" size="50" name="pass" id="pass" class="required" minlength="6"  value="<?php echo $_SESSION['pass'] ?>"/></br>
                                <input type="submit" value="Đăng nhập" name="login"/><br>
                            </form>
                            <?php
                        }
                    } else {
                        ?>
                        <form action="admin/login" method="POST" id="login">
                            <label><strong>Email:<span>(*)</span></strong></label>
                            <input type="text" size="50" name="email" id="email" class="required email"/></br>
                            <label ><strong>Mật khẩu:<span>(*)</span></strong></label>
                            <input type="password" size="50" name="pass" id="pass" class="required" minlength="6"/></br>
                            <input type="submit" value="Đăng nhập" name="login"/><br>
                        </form>
                        <?php
                    }
                    ?>
                </fieldset>
            </div>
        </div>
    </body>
</html>
